﻿#pragma once
#include "ApDefine.h"
#include "ApMainWindow.h"
#include <AsMethodDebug>

class ApEnvironment : public QObject, public AsEnvironment {
	Q_OBJECT

public:
	ApEnvironment(int argc, char* argv[]);
	~ApEnvironment();

private:
	ApMainWindow* wMain;

private:


public:
	// 环境构造前预初始化
	static inline void preinit() {
		As::InstallDebugOutputConsole();

	}
	// 构建所有对象
	inline void construct() override {
		initEnvironment();
		initMainWindow();

	}

private:
	// 初始化应用程序环境
	inline void initEnvironment() {
		setupEnvironmentVariables(AsEnvironment::AutoSave);

	}
	// 初始化主窗体
	inline void initMainWindow() {
		wMain = new ApMainWindow();
		wMain->show();

	}

private:


private:


private:

};
